<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>病虫害数据管理 | 登录</title>
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
    <link rel="stylesheet" th:href="@{/plugin/AdminLTE/bootstrap/css/bootstrap.min.css}" href="../static/plugin/AdminLTE/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-awesome.min.css">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css">
    <link rel="stylesheet" th:href="@{/plugin/AdminLTE/dist/css/AdminLTE.min.css}" href="../static/plugin/AdminLTE/dist/css/AdminLTE.min.css">
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
</head>
<body class="hold-transition login-page" th:style="'background:url(' + @{'/img/' + ${app.name} + '.jpg'} + ');'">
<div class="login-box">
    <div class="login-logo">
        <a href="#"><b>病虫害数据管理系统</b></a>
    </div>
    <div class="login-box-body" style="border: solid">
        <p class="login-box-msg">用户登录</p>
        <form th:action="@{/login}" th:object="${user}" th:method="post" method="post" role="form" action="/login">
            <div class="form-group has-feedback">
                <label class="control-label" for="userName">用户名</label>
                <input type="text" class="form-control" placeholder="" id="userName" th:field="*{userName}">
                <span class="glyphicon glyphicon-user form-control-feedback"></span>
            </div>
            <div class="form-group has-feedback">
                <label class="control-label" for="password">密码</label>
                <input type="password" class="form-control" placeholder="" id="password" th:field="*{password}">
                <span class="glyphicon glyphicon-lock form-control-feedback"></span>
            </div>
            <div class="row">
                <div class="col-xs-8">
                    <a th:href="@{/register}" href="register.html" class="text-center">新用户注册</a>
                </div>
                <div class="col-xs-4">
                    <button type="submit" class="btn btn-primary btn-block btn-flat">登录</button>
                </div>
            </div>
        </form>
        <p></p>
        <div th:if="${param.error}" class="alert alert-danger">
            用户名或密码无效.
        </div>
        <div th:if="${param.logout}" class="alert alert-info">
            注销成功.
        </div>
        <div th:if="${param.auth}" class="alert alert-danger">
            您尚未登陆.
        </div>
    </div>
</div>
<script th:src="@{/plugin/AdminLTE/plugins/jQuery/jquery-2.2.3.min.js}" src="../static/plugin/AdminLTE/plugins/jQuery/jquery-2.2.3.min.js"></script>
<script th:src="@{/plugin/AdminLTE/bootstrap/js/bootstrap.min.js}" src="../static/plugin/AdminLTE/bootstrap/js/bootstrap.min.js"></script>
<script th:src="@{/plugin/AdminLTE/dist/js/app.min.js}" src="../static/plugin/AdminLTE/dist/js/app.min.js"></script>
</body>
</html>
